package com.zz.springrabbitmq.listener;

import com.zz.springrabbitmq.constant.Constants;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

@Component
public class SimpleListener {
    @RabbitListener(queues = Constants.SIMPLE_QUEUE)
    public void queueListener(String message) {
        System.out.println("接收到消息：" + message);
    }
}
